package org.jeecg.module.flow.meter.tcpserver.entity;

import com.baomidou.mybatisplus.annotation.*;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.springframework.format.annotation.DateTimeFormat;

import java.math.BigDecimal;
import java.util.Date;

/**
 * @Author: 86176
 * @Date: 2024-08-02 8:41
 * @Version: 1.0
 */
@Data
@TableName("ft_meter_device_log")
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
public class MeterDeviceLog {
    /**水表id*/
    @TableId(type = IdType.ASSIGN_ID)
    private String id;

    /**表身号*/
    private String meterNumber;

    private Integer valveStatus;

    private BigDecimal monthWaterVolume;

    private BigDecimal totalWaterVolume;

    private Double voltage;

    /**电压状态 0正常 1欠压*/
    private Integer voltageStatus;

    /**温度*/
    private Integer temperature;

    /**信号强度*/
    private Integer riss;

    /**磁干扰 0无 1有*/
    private Integer magnetic;

    /**信号强度*/
    private Integer fault;

    private String tenantId;

    @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
    @TableField(fill = FieldFill.INSERT)
    private Date createTime;

    @JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
    private Date lastUploadTime;

    /**时间年月*/
    private String yearmonth;

}
